<%@ include file="/common/taglibs.jsp"%>

<head>
    <title><fmt:message key="userList.title"/></title>

    <meta name="heading" content="<fmt:message key='userList.heading'/>"/>
    <meta name="menu" content="MaterialMenu"/>
</head>


<c:set var="buttons">
    <input type="button" style="margin-right: 5px"
           onclick="location.href='<c:url value="/editUser.html?method=Add&from=list"/>'"
           value="<fmt:message key="button.add"/>"/>
</c:set>

<c:out value="${buttons}" escapeXml="false" />

<s:set name="users" value="users" scope="request"/>
<display:table name="users" class="table" requestURI="" id="userList" export="true" pagesize="25">
    <display:column property="id" sortable="true" href="editUsers.html?from=list"
                    paramId="id" paramProperty="id" titleKey="user.id"/>
    <display:column property="username" sortable="true" titleKey="user.username"/>
    <display:column property="fullName" sortable="true" titleKey="activeUsers.fullName"/>
    <display:column property="email" sortable="true" titleKey="user.email"/>
<display:column sortProperty="enabled" sortable="true" titleKey="user.enabled" style="width: 16%; padding-left: 15px" media="html">
        <input type="checkbox" disabled="disabled" <c:if test="${userList.enabled}">checked="checked"</c:if>/>
    </display:column>
    <display:column property="enabled" titleKey="user.enabled" media="csv xml excel pdf"/>

    <display:setProperty name="paging.banner.item_name" value="user"/>
    <display:setProperty name="paging.banner.items_name" value="users"/>
    <display:setProperty name="export.excel.filename" value="User List.xls"/>
    <display:setProperty name="export.csv.filename" value="User List.csv"/>
    <display:setProperty name="export.pdf.filename" value="User List.pdf"/>
</display:table>

<c:out value="${buttons}" escapeXml="false" />
